package com.hydl.power.mapper;

import com.hydl.power.pojo.Navbar;
import com.hydl.power.pojo.PowerRoom;
import com.hydl.power.pojo.PowerRoomExample;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface PowerRoomMapper {
    /*删除配电房信息*/
    int deleteByPrimaryKey(Integer id);

    /*添加配电房信息*/
    int insert(PowerRoom record);

    List<PowerRoom> selectByExample(PowerRoomExample example);

    PowerRoom selectById(Integer id);

    /*查询所有配电房信息*/
    List<PowerRoom> selectByConditions(@Param("pageNumKey") Integer pageNum,@Param("pageSizeKey") Integer pageSize);


    /** 按条件查询配电房*/
    List<PowerRoom> selectByCityId(@Param("pageNumKey") Integer pageNum,@Param("pageSizeKey") Integer pageSize,String cityId,String projectId );
    List<PowerRoom> selectByTokenId(@Param("pageNumKey") Integer pageNum,@Param("pageSizeKey") Integer pageSize,String cityId,String projectId,String token);

    int selectCount();

    /*修改信息*/
    int updatePowerRoomById(Integer id,String roomName,String address,String highVoltageBoard,String lowPressureTank);
    /** 按项目id查询配电房*/
    List<PowerRoom> selectNavbarByNavId(String projectId);
    /** 按城市id查询配电房*/
    List<PowerRoom> selectByAreaId(String cityId);

    PowerRoom selectByRoomId(String roomId);

    List<PowerRoom> all();


    List<PowerRoom> queryPowerroom(String projectId);

    List<PowerRoom> getPowerRoomByProjectId(String toString);

    /*根据项目id查询配电房条数*/
    int selectCountByProjectId(String projectId);
/*    *//*根据项目id、token查询配电房条数*//*
    List<PowerRoom> queryPowerroomByToken(String projectId);*/

    List<PowerRoom> queryPowerRoomLike(@Param("pageNumKey") Integer pageNum, @Param("pageSizeKey") Integer pageSize,String text,String projectId);

    String getPowerRoomNumberByProjectId(String projectId);

    List<PowerRoom> getPowerRoom(String roomName);

    PowerRoom queryVoltageBoard(String projectId);
}
